package com.xuecheng.content.convert;

import com.xuecheng.api.content.model.dto.CourseTeacherDTO;
import com.xuecheng.api.content.model.vo.CourseTeacherVO;
import com.xuecheng.content.entity.CourseTeacher;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

import java.util.List;


/**
 * @author 黄子弟
 * @Date 2021/12/8
 */

@Mapper
public interface CourseTeacherConvert {

    CourseTeacherConvert INSTANCE = Mappers.getMapper(CourseTeacherConvert.class);
    @Mapping(source = "id",target = "courseTeacherId")
    CourseTeacherDTO po2dto(CourseTeacher courseTeacher);


    CourseTeacherDTO vo2dto(CourseTeacherVO courseTeacherVO);

    //将pos转换为dtos
    List<CourseTeacherDTO> entitys2dtos(List<CourseTeacher> courseTeachers);



}
